/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package koneksi.DBF;
import java.sql.Connection;
import java.sql.DriverManager;

/**
 *
 * @author rosi
 */
public class Koneksi {

   public static Connection open() {
        String dbname = "jdbc:odbc:coba";
        Connection con = null;
        try {
            Class.forName("oracle.jdbc.driver.OracleDriver");
            con = DriverManager.getConnection(dbname);
//            Statement stat = con.createStatement();
            System.out.println("Connection OK");
        } catch (Exception e) {
            System.out.println("error: " + e.getMessage());
        }
        return con;
    }
}
